//
//  AcitvityPhotoCollectionCell.m
//  SXH
//
//  Created by Ryan on 15/12/9.
//  Copyright © 2015年 lyss. All rights reserved.
//
//发现_03 发现_03_02
#import "AcitvityPhotoCollectionCell.h"
#import "UIImageView+AFNetworking.h"
@implementation AcitvityPhotoCollectionCell
- (instancetype)initwithModel:(HotSpotModel *)model
{
    if (self) {
        self.mainImage = [[UIImageView alloc]init];
        [self addSubview:self.mainImage];
        [self.mainImage setImageWithURL:[NSURL URLWithString:IMAGE_STRING(model.album_thumb)]];
        [self.mainImage mas_makeConstraints:^(MASConstraintMaker *make) {
            make.edges.equalTo(self).with.insets(UIEdgeInsetsMake(0, 0, 0, 0));
        }];
        
        self.zanBtn = [UIButton buttonWithType:UIButtonTypeCustom];
        [self addSubview:self.zanBtn];
        [self.zanBtn mas_makeConstraints:^(MASConstraintMaker *make) {
            make.right.equalTo(@(-6));
            make.bottom.equalTo(@(-6));
            make.width.equalTo(@18);
            make.height.equalTo(@18);
        }];
//        if (self)
//        {
//            [self.zanBtn setImage:[UIImage imageNamed:@"发现_03"] forState:UIControlStateNormal];
//        }
//        else
//        {
//            [self.zanBtn setImage:[UIImage imageNamed:@"发现_03_02"] forState:UIControlStateNormal];
//        }
    }
    return  self;
}
@end
